package net.uhuijia.zb.userzhubolive.service;

import net.uhuijia.appbase.service.BaseService;
import net.uhuijia.user.usermall.persistence.model.UserMall;
import net.uhuijia.vo.zb.UserZhuboListVo;
import net.uhuijia.vo.zb.ZbDetailVo;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import net.uhuijia.zb.userzhubolive.persistence.model.UserZhuboLive;
import net.uhuijia.zb.userzhubolive.persistence.model.UserZhuboLiveExample;

import java.util.List;


@Service
@Transactional
public interface UserZhuboLiveService
     extends BaseService<UserZhuboLive,UserZhuboLiveExample> {


    /**
     * 分页查询主播直播列表
     * @param example
     * @return
     */
    List<UserZhuboLive> findUserZhuBoLiveByPage(UserZhuboLiveExample example);

    /**
     * 查询主播直播列表数量
     * @param example
     * @return
     */
    int findUserZhuBoLiveCount(UserZhuboLiveExample example);

    /**
     * 将UserZhuboLive 转换成UserZhuboListVo
     * @param userZhuboLive
     * @return
     */
    UserZhuboListVo userZhuboLiveWrapUserZhuboListVo(UserZhuboLive userZhuboLive);

    /***
     * 直播详情
     * @param userMall
     */
    ZbDetailVo zbOnlineDetail(UserMall userMall,String liveId);

    /**
     * 查询主播正在直播的信息
     * @param userId
     * @return
     */
    UserZhuboLive getUserZhuboOnlineByUserId(String userId);

}